package cn.iocoder.yudao.module.member.dal.mysql.user;

import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.member.dal.dataobject.user.MemberUserPriceDetailDo;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface MemberUserPriceDetailMapper extends BaseMapperX<MemberUserPriceDetailDo> {

    List<MemberUserPriceDetailDo> selectByUserId(Long userId) ;

    default void deleteByUserId(Long userId){
        delete(MemberUserPriceDetailDo::getUserId, userId);
    }

    default void saveBatchs(List<MemberUserPriceDetailDo> prices){
        insertBatch(prices);
    }
}
